home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Tech Arsenal 1
/
Tech Arsenal (Arsenal Computer).ISO
/
tek-01
/
winlib1.zip
/
EXAMPLES.ZIP
/
EXAM43.C
< prev
next >
Wrap
Text File
|
1991-01-06
|
1KB
|
28 lines
#include <window.h>
#define NORM CREATE_VIDEO_ATTRIBUTE(black,white) /* define video
attribute */
#define BLUEONBLACK CREATE_VIDEO_ATTRIBUTE(black,blue) /* define
video attribute */
main()
{
WPOINTER w; /* pointer to a window structure */
WindowInitializeSystem(); /* system initialization function */
WindowSaveInitial(0);
w = WindowInitialize(BORDER,1,1,30,10,BLUEONBLACK,NORM,SINGLEBOX);
WindowOpen(w); /* display window on the screen */
WindowWriteString(w,"Press a key to slide right",1,1);
WindowDisplay(w,1,NOEFFECT);
GET_KEY();
WindowSlide(w,RIGHT,20);
WindowWriteString(w,"Press a key to slide down",2,1);
GET_KEY();
WindowSlide(w,DOWN,10);
WindowWriteString(w,"Press a key to slide left",3,1);
GET_KEY();
WindowSlide(w,LEFT,20);
WindowWriteString(w,"Press a key to slide up",4,1);
GET_KEY();
WindowSlide(w,UP,20);
}